<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Largezhou\Admin\Traits\TreeSelectOptions;

class Menu extends Model
{
    use TreeSelectOptions;

    protected $fillable = ['parent_id', 'title', 'url', 'icon', 'order'];

    public function parent()
    {
        return $this->belongsTo(static::class, 'parent_id');
    }
}
